﻿using System;
using System.IO;
using System.Security.Principal;
using System.Text;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Hosting;
using System.Web.Security;
using Microsoft.VisualStudio.TestTools.UnitTesting;
using nanoCMS.Core.Concrete;

namespace nanoCMS.Core.Test
{
    [TestClass]
    public class WorldContext_Test
    {
        private WorldContext worldContext;

        [TestInitialize]
        public void Init()
        {
            worldContext = new WorldContext();
        }

        [TestMethod]
        public void Connection_to_database()
        {
            Entities context  = new Entities(worldContext.EntityConnectionString);
        }


        [TestMethod]
        public void Fake_HttpContext()
        {
            HttpContext.Current = Helpers.FakeHttpContext("1");
            WorldContext wContext = new WorldContext();
            Assert.AreEqual(1, wContext.CurrentUserID);
        }
    }
}
